package com.hl.sfzy.controller.course;

import com.hl.sfzy.service.course.CourseVideoService;
import com.hl.sfzy.utils.R;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import java.util.List;

/**
 * @program: sfzy
 * @description:
 * @author: xiaoyan
 * @create: 2024-09-09 21:36
 **/

@RestController
@RequestMapping("/CourseVideo")
public class CourseVideoController {

    @Autowired
    private CourseVideoService courseVideoService;

    @GetMapping("/allById")
    public R selectByCourseId(long id){
        List list = courseVideoService.selectByCourseId(id);
        System.out.println(list);
        return R.success(list);
    }
}
